package com.hm.ibsm.domain.mg;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.EnumType;
import javax.persistence.Enumerated;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import com.hm.common.def.ActivateDef;
import com.hm.common.def.GenderDef;
import com.hm.ibsm.util.BaseDomain;
import com.hm.ibsm.util.R;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * @author shishun.wang
 * @date 下午11:31:07 2017年1月31日
 * @version 1.0
 * @describe
 */
@Setter
@Getter
@ToString
@Entity
@Table(name = R.DB.PREFIX + "USER")
public class UserDomain extends BaseDomain {

	private static final long serialVersionUID = -569040841053048212L;

	@Column(nullable = false)
	private String userName;

	@Column(nullable = false)
	private String account;

	@Column(nullable = false)
	private String pwd;

	private String email;

	private String mobile;

	private String portrait;

	@Enumerated(EnumType.STRING)
	private GenderDef gender;

	@Temporal(TemporalType.TIMESTAMP)
	private Date birthday;

	@Enumerated(EnumType.STRING)
	private ActivateDef activate = ActivateDef.DISABLE;

}
